<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>模版数据管理 HDSysCms</title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/admin/layui/css/layui.css" media="all">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/admin/style/admin.css" media="all">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/admin/layui_ext/dtree/dtree.css">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/admin/layui_ext/dtree/font/dtreefont.css">
<link rel="stylesheet" href="<?php echo getcdnurlhost() ?>/markdown/css/editormd.min.css" />
</head>
<body data="HDSYSCMS 2021本系统受国家版权局保护请勿破解或者二次开发传播">
<div class="layui-col-md12">
<div style="padding-left: 10px;line-height: 35px;" class="layui-card">
<span class="layui-breadcrumb">
<a href="">模版管理</a>
<a href=""><?php echo set_get('id') ?></a>
</span>
</div>
</div>
<div class="layui-fluid">
<div class="layui-row layui-col-space15">
<div class="layui-col-md12">
<div class="layui-card">
<div class="layui-tab layui-tab-brief">
<ul class="layui-tab-title">
<li onclick="window.location.href='index.php?m=manage&c=Ad&a=document&id=<?php echo  set_get('id')  ?>'">页面视图文件</li>
<li onclick="window.location.href='index.php?m=manage&c=Ad&a=table&id=<?php echo  set_get('id')  ?>'">动态标签</li>
<li onclick="window.location.href='index.php?m=manage&c=Ad&a=mode&id=<?php echo  set_get('id')  ?>'">模块文件</li>
<li class="layui-this" onclick="window.location.href='index.php?m=manage&c=Ad&a=info&id=<?php echo  set_get('id')  ?>'">模版信息</li>
<li onclick="window.location.href='index.php?m=manage&c=Template&a=back_template&id=<?php echo  set_get('id')  ?>'">备份模版</li>
</ul>
</div>
<div class="layui-card-body">
<form class="layui-form" action="#">
<input type="hidden" id="id" name="id" value="<?php echo set_get('id') ?>">
<div class="layui-form-item">
<label class="layui-form-label">模版目录</label>
<div class="layui-input-inline">
<input type="text" name="" disabled value="<?php echo set_get('id') ?>" lay-verify="required" placeholder="默认所在目录" autocomplete="off" class="layui-input">
</div>
<div class="layui-form-mid layui-word-aux">导入跟随</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label">名称</label>
<div class="layui-input-inline">
<input type="text" name="name" value="<?php echo $param_josn_array['name'] ?>" lay-verify="required" placeholder="模版名称" autocomplete="off" class="layui-input">
</div>
<div class="layui-form-mid layui-word-aux"></div>
</div>
<div class="layui-form-item">
<label class="layui-form-label en">模版作者</label>
<div class="layui-input-inline">
<input type="text" name="by" value="<?php echo $param_josn_array['by'] ?>" placeholder="模版作者" autocomplete="off" class="layui-input">
</div>
<div class="layui-form-mid layui-word-aux"></div>
</div>
<div class="layui-form-item">
<label class="layui-form-label">模版说明</label>
<div class="layui-input-inline" style="width: 400px;">
<input type="text" name="info" placeholder="模版说明" value="<?php echo $param_josn_array['info'] ?>" autocomplete="off" class="layui-input">
</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label">模版图片</label>
<div class="layui-input-inline" style="width: 230px;height: 165px;">
<img id="imges-img" lay-src="<?php
$param_id=set_get('id');
if (file_exists(HDSYS_DIR_SYS . "/templates/{$param_id}/statics/templatesBy.png")) {
echo "../templates/{$param_id}/statics/templatesBy.png";
} else {
echo '../statics/no.png';
}
?>" class="logos" />
<input type="hidden" name="imges" id="imges" value="<?php echo isset($param_db_array_value['imges']) ? $param_db_array_value['imges'] : '../statics/no.png'  ?>" placeholder="" class="layui-input">
</div>
<div style="line-height: 75px;margin-left: 20px;" class="layui-form-mid layui-word-aux">
<button type="button" class="layui-btn setimges layui-btn-primary" id="setimges">选择图片</button>
</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label"></label>
<div class="layui-input-block">
<button class="layui-btn" lay-submit lay-filter="post">保存模版信息</button>
</div>
</div>
</form>
<style>.logos {width: 235px;height: 165px;border: #EEEEEE;border-style: solid;border-width: 1px;}</style>
</div>
</div>
</div>
</div>
</div>
<style>.dtree-zdy-item-this {background-color: #deeefd00 !important;}.dtree-zdy-item:hover {background-color: #deeefd !important;}.dtree-zdy-item cite {font-size: 16px !important;}.dtree-zdy-item:hover cite {color: #1b84ed !important;}.dtree-zdy-dtreefont {font-size: 18px !important;}.dtree-zdy-ficon {color: #2F4056 !important;}.dtree-zdy-icon {color: #2F4056 !important;}.dtree-zdy-checkbox:hover {color: #5FB878 !important;}.dtree-zdy-choose {color: #5FB878 !important;}.dtree-nav-first-line,.dtree-nav-line,.dtree-nav-last-line {line-height: 40px;}</style>
<?php adminechohtnl(); ?>
<div id="foot">Copyright © 2019-2023 <a href="https://www.HDSysCms.Com?pro" target="_blank">HDSysCms <?php echo HDSYS_VERSION; ?></a> <br>
All Rights Reserved </div>
<script src="<?php echo getcdnurlhost() ?>/admin/layui/layui.js"></script>
<script>layui.config({base: '<?php echo getcdnurlhost() ?>/admin/'}).use(['form', 'layer', 'element', 'flow', 'upload'], function() {var admin=layui.admin,$=layui.$,form=layui.form,upload=layui.upload,element=layui.element;var flow=layui.flow;flow.lazyimg();form.on('submit(post)', function(data) {data=data.field;layer.load(1);$.ajax({type: "post",url: 'index.php?m=manage&c=Ad&a=info_ajax',data: {id: '<?php echo set_get('id') ?>',name: data.name,info: data.info,by: data.by,imges: data.imges,},dataType: "json",success: function(ret) {layer.closeAll('loading');layer.msg(ret.msg);}});return false;});var uploadInst=upload.render({elem: '#setimges',url: 'index.php?m=manage&c=UpFile&a=UpTemplatesBy&id=<?php echo $param_id ?>',before: function(obj) {layer.load(0);},done: function(res) {layer.closeAll();if (res.code==-1) {return layer.msg(res.msg);}console.log(res);$('#imges-img').attr('src', "../templates/<?php echo $param_id ?>/statics/templatesBy.png?" + new Date().getTime());$('#imges').val(res.url);},error: function() {layer.closeAll();layer.alert('上传失败')}});});</script>
<script charset="utf-8" src="<?php echo getcdnurlhost() ?>/kindeditor/kindeditor-all-min.js"></script>
<script charset='utf-8' src='".getcdnurlhost()."/kindeditor/app.js'></script>
</body>
</html>